<include file='Public:head' />
<body class="J_scroll_fixed">
<div class="wrap J_check_wrap">
	<div class="nav">
		<ul class="cc">
		      <li ><a href="{:U('index',array('position_psid'=>$_GET['position_psid'],'verifystate'=>2))}">广告列表</a></li>
		      <li  class="current"><a href="">编辑广告</a></li>
    	</ul>
	</div>
	<div class="h_a">广告属性</div>
	<form action="{:U('Ad/edit')}" method="post" class="J_ajaxForms"  name="myform" id="myform">
		<div class="table_full">
			<table width="100%"  class="table_form" >
				<tr>
					<th width="120">广告位置：</th>
					<td class="y-bg">
						<span class="must_red">*</span><select name="position_psid"  id='position_psid'>
							<option value="">请选择广告位置</option>
							<foreach name='position' item='v'>
							   	<option value='{$v.psid}' <if condition='$v["psid"] eq $data["position_psid"]'> selected='selected' </if>>{$v.position_name}</option>
							</foreach>
						</select>
					</td>
				</tr>
				<tr>
					<th width="120">广告名称：</th>
					<td class="y-bg">
						<span class="must_red">*</span><input type="text" class="input" name="name" id="name" size='50' value="{$data.name}" />
					</td>
				</tr>
				<if condition='C("cfg_language_en")'>
				<tr>
					<th width="120">(英)广告名称：</th>
					<td class="y-bg">
						<input type="text" class="input" name="name_en" id="name_en" size='50' value="{$data.name_en}" />
					</td>
				</tr>
				</if>

				<tr>
					<th width="120">图片：</th>
					<td class="y-bg">
						<input type="text" name="pic" id="pic" value="{$data.pic}" size="50" class="input"  ondblclick="image_priview(this.value);"/> 
              			<input type="button" class="button" onclick="javascript:flashupload('image_images', '附件上传','pic',submit_images,'{$Think.const.CONTROLLER_NAME}',1,1,'{$Think.Config.cfg_image}')" value="上传图片" /><span class="gray"> 双击可以查看图片！</span>
					</td>
				</tr>
				<if condition='C("cfg_language_en")'>
				<tr>
					<th width="120">(英)图片：</th>
					<td class="y-bg">
						<input type="text" name="pic_en" id="pic_en" value="{$data.pic_en}" size="50" class="input"  ondblclick="image_priview(this.value);"/> 
              			<input type="button" class="button" onclick="javascript:flashupload('image_images', '附件上传','pic_en',submit_images,'{$Think.const.CONTROLLER_NAME}',1,1,'{$Think.Config.cfg_image}')" value="上传图片" /><span class="gray"> 双击可以查看图片！</span>
					</td>
				</tr>
				</if>
				<tr>
					<th width="120">广告链接：</th>
					<td class="y-bg">
						<textarea name='url' id='url' style="width:90%;height:80px">{$data.url}</textarea>
					</td>
				</tr>
				<tr>
					<th width="120">排序：</th>
					<td class="y-bg">
						<input type="text" class="input" name="sort" id="sort" value="{$data.sort}" />
					</td>
				</tr>
				<tr>
					<th width="120">状态：</th>
					<td class="y-bg">
					<label >
						<input type="radio" name="verifystate" value="1" <if condition='$data["verifystate"] eq 1'>checked='checked'</if>> <span>未审核</span>
					</label>
					<label >
						<input type="radio" name="verifystate" value="2" <if condition='$data["verifystate"] eq 2'>checked='checked'</if>> <span>审核通过</span>
					</label>
					</td>
				</tr>

				
				
			</table>
		</div>
		<div class="">
			<div class="btn_wrap_pd">
				<input type="hidden" name='aid' value="{$data.aid}" />
				<button class="btn btn_submit mr10 J_ajax_submit_btn" type="submit">编辑</button>

			</div>
		</div>
	</form>
</div>
<script type="text/javascript" src="__PUBLIC__/js/mod.common.js"></script>
<script type="text/javascript" src="__PUBLIC__/js/mod.content_addtop.js"></script>
<script type="text/javascript" src='__PUBLIC__/js/mod.ad.js'></script>
</body>
</html>